package com.et.controller;

import com.et.bean.EtUser;
import com.et.service.UserService;
import com.et.service.impl.UserServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


@RestController
public class UserController {
    @Autowired
    UserService userService;
    @RequestMapping("/user/{id}")
    public EtUser index(@PathVariable Integer id) {
        EtUser etUser=userService.get(id);
        return etUser;

    }

}